home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The 640 MEG Shareware Studio 2
/
The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO
/
bbs
/
testf10.zip
/
TESTFILE.DOC
< prev
next >
Wrap
Text File
|
1993-01-23
|
2KB
|
76 lines
This is just a small utility that I made up so my callers can view any
compression kept on my BBS. This program will check the signature of the
archive to determine it's type instead of relying on a suffix. I normally
only have ARJ on my system, but I figured what the heck, I might as well
include all seven... <g>
The following errorlevels will be sent to DOS upon execution:
0 = Unknown archive format
1 = ARC format
2 = ARJ format
3 = LZH format
4 = PAK format
5 = SQZ format
6 = ZIP format
7 = ZOO format
The versions below are the archive utilities that I have tested this with:
ARC - Version 6.00 by System Enhancement Associates
ARJ - Version 2.30 by Robert K. Jung
LHA - Version 2.12 by Haruyasu Yoshizaki
PAK - Version 2.51 by NoGate Consulting
SQZ - Version 1.08.2 by J I Hammarberg
ZIP - Version 2.04c by PKWare Inc.
ZOO - Version 2.1 by Rahul Dhesi
The calling format for the executable is
TESTFILE {archive}
Here is a copy of my PCBVIEW.BAT file:
@echo off
testfile %1
if errorlevel == 7 goto zoo
if errorlevel == 6 goto zip
if errorlevel == 5 goto sqz
if errorlevel == 4 goto pak
if errorlevel == 3 goto lzh
if errorlevel == 2 goto arj
if errorlevel == 1 goto arc
if errorlevel == 0 goto error
goto end
:arc
arc l %1 > pcbview.txt
goto end
:arj
arj l %1 > pcbview.txt
goto end
:lha
lha l %1 > pcbview.txt
goto end
:pak
pak v %1 > pcbview.txt
goto end
:sqz
sqz l %1 > pcbview.txt
goto end
:zip
viewzip %1
goto end
:zoo
zoo l %1 > pcbview.txt
goto end
:error
:end